<?php
/**
 * This class defines the models used for interacting with the database
 * @author Clem Bradley
 */
class Whiskey_Model {


    /**
     *
     * @var Database Instance of the database driver
     */
    public $db;

    /**
     *
     * @var Whiskey_Model Singleton instance of our class
     */
    private static $model_instance;

    /**
     * Class follows the singleton pattern, so the constructor is private
     */
    private function __construct()
    {
        //TODO Need to initialize the $db property to getInstance of the database
    }

    /**
     * Singleton method used to return the one instance of this class
     * @return Model
     */
    public static function getInstance()
    {
        if(!self::$model_instance)
        {
            self::$model_instance = new Whiskey_Model();
        }

        return self::$model_instance;
    }

}
